/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package net.icom.maf.event;

/**
 *
 * @author Josh
 */
public class KeyEvent extends Event {

    public static final String EVENT_NAME = "keyevent";
    
    public static final int KEY_STATE_UP    = 0;
    public static final int KEY_STATE_DOWN  = 1;
    
    private int keyState = KEY_STATE_DOWN;
    private long keyDownTime = 0;
    
    private int keyCode = -1;
    private int gameAction = -1;
    
    public KeyEvent(){
        super(); 
        setName( EVENT_NAME );
    }
    
    public KeyEvent( int keyState ){
        this.keyState = keyState;
    }

    public int getKeyState() {
        return keyState;
    }

    public void setKeyState(int keyState) {
        this.keyState = keyState;
    }

    public long getKeyDownTime() {
        return keyDownTime;
    }

    public void setKeyDownTime(long keyDownTime) {
        this.keyDownTime = keyDownTime;
    }

    public int getKeyCode() {
        return keyCode;
    }

    public void setKeyCode(int keyCode) {
        this.keyCode = keyCode;
    }

    public int getGameAction() {
        return gameAction;
    }

    public void setGameAction(int gameAction) {
        this.gameAction = gameAction;
    }    
    
}
